fix(hypatia): triage all 15 findings — 8 at source, 7 baselined (closes the red gate) - #146
Merged
Merged
Conversation
Source fixes:
- .hypatia-ignore: reword the API-key comment so the secret matcher's
assignment-shape no longer fires on its own exemption text (the critical)
- my-hir: replace guarded unwrap with a match on into_iter().next()
- my-lint: is_some_and guards kill 2 genuine empty-name panics
- my-llvm: SAFETY marker directly adjacent to the unsafe block (the
16-line invariant argument sat too far above for the adjacency check)
- ENSAID_CONFIG.a2ml: abi-verify workflow now targets the real Idris tree
via ipkg --build (per-file --check is a fake gate, exit 0 on missing module)
- docs/wiki/roadmap/compiler.md: 'Planned: src/{hir,mir,runtime}' paths
now point at the shipped crates
Baseline (.hypatia-baseline.json, 7 entries, expires 2026-10-27, #145):
parser.rs self.expect() name-collision FP; my-fmt infallible Write-to-String
unwraps; my-llvm internal-invariant unwraps; my-mir/string.rs deliberate
invariant expects; measure_depth example; modules.md illustrative paths.
Validated against apply-baseline.sh locally: 7 suppressed, 0 kept, exit 0.
Hygiene (owner-approved salvage from the 07-26 sweep stash):
- .gitignore: secrets/env entries only (.env, *.pem, *.key, .venv/)
- mise.toml: replace 30-tool all-'latest' boilerplate with pinned rust 1.97.0
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
hyperpolymath
added a commit
that referenced
this pull request
Jul 27, 2026
#147) Follow-up to #146 — the one finding that survived. hypatia's `unsafe_block` rule is a bare `unsafe\s*\{` regex (`lib/rules/code_safety.ex`): it flags every unsafe block regardless of documentation, so no SAFETY comment can ever satisfy it (the adjacency fix in #146 was a no-op against a rule that never looks). The single unsafe block in my-llvm is mandatory (inkwell declares `build_gep` unsafe) and fully documented, so this uses the same scoped `.hypatia-ignore` mechanism as the existing `coq_axiom`/`transmute` keyword-match exemptions — a permanent fact should not be expiring baseline debt. Upstream rule fix is a candidate for hypatia itself. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This was referenced Jul 29, 2026
Closed
hyperpolymath
added a commit
that referenced
this pull request
Jul 29, 2026
…al (#148) Closes out the my-lang session by recording current state in-repo (not only in dev-notes) and fixing the documentation defects found while doing it. ## The Justfile was parse-dead `README.md` documented `just build` / `just test` as the quickstart. Neither worked: a `//` C-style comment on line 2 made `just` reject the **entire file** (`error: unknown start of token '.'`), so no recipe was reachable — and every recipe was an `@echo` stub regardless. `just verify` checked `.machine_read/` (a path that has never existed) and swallowed every failure with `||`, so it always reported success. Now: real cargo recipes, `-all` variants for the LLVM-dependent crate, and a `verify` that exits non-zero. **Verified by running them** — `just build` exits 0; `just test` reports **221 passing, 0 failing**. *(Estate note: 143 of 751 Justfiles across the estate are parse-dead by the same class of defect — 76× unindented shell blocks, 35× `//` comments, 32× `Justfile`/`justfile` case collisions. Out of scope here; recorded in dev-notes.)* ## For machines — `.machine_readable/6a2/STATE.a2ml` - version `0.1.0` → `0.2.0` (was drifting from `Cargo.toml`) - new `[security-posture]`: distinguishes **expiring baseline debt** (7 entries → 2026-10-27, #145) from **permanent scoped exemptions** (3, each a rule-precision problem), plus upstream rule-fix candidates - new `[toolchain]`; `known-local-limitation` records that `my-llvm` needs system LLVM 21, so a bare workspace build failure is not misread as a regression - dialect model corrected: **solo ⊂ duet ⊂ ensemble**, with `me` an outside projector — not four co-equal surfaces - `superseded-branch` records the evidence that `feat/stdlib-fs-env-format` is safe to delete ## For humans — README + CHANGELOG Quickstart matches reality (incl. the my-llvm caveat); dialect containment; measured test count (137+ → 221); governance/security posture; `contractiles/` path corrected (it is under `.machine_readable/`, not the repo root). CHANGELOG gains Security/Fixed/Changed entries for #143, #146, #147. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
hyperpolymath
added a commit
that referenced
this pull request
Aug 12, 2026
… path real The README documented `just build` / `just test` as the quickstart, but the Justfile was PARSE-DEAD — a `//` C-style comment on line 2 made `just` reject the whole file (`error: unknown start of token '.'`), so no recipe was reachable; and every recipe was an `@echo` stub anyway. `just verify` checked a `.machine_read/` path that has never existed and swallowed failures with `||`, so it always claimed success. Justfile: real cargo recipes (build/test/lint/fmt/check/proofs/pipeline), split `-all` variants for the LLVM-dependent crate, and a `verify` that exits non-zero when a path is missing. Parse- and run-verified: `just build` exits 0, `just test` reports 221 passing / 0 failing. STATE.a2ml (machines): version 0.1.0 -> 0.2.0 to match Cargo.toml; current session + maintenance status; a new [security-posture] section distinguishing EXPIRING baseline debt from PERMANENT scoped exemptions, with the three active exemptions and their rule-precision rationale, plus upstream rule-fix candidates; a [toolchain] section; the my-llvm/LLVM-21 local limitation recorded so a bare workspace build failure is not misread as a regression; and the dialect model corrected from four co-equal surfaces to solo ⊂ duet ⊂ ensemble with me as an outside projector. README (humans): quickstart now matches reality incl. the my-llvm caveat; dialect containment; measured test count (137+ -> 221); governance/security posture; `.machine_readable/` and `_exploratory/` documented, and the `contractiles/` path corrected (it is not at the repo root). CHANGELOG: Security / Fixed / Changed entries for #143, #146, #147. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes the last red gate on main (governance / Validate Hypatia Baseline, failing since ≥07-22 when the scanner started actually working).
Fixed at source (8):
.hypatia-ignore:86"Generic API key": self-referential FP; the comment explaining the API-key exemption itself contained theKEY=\"...\"assignment shape. Reworded.match; my-lint 2× genuine empty-name panics →is_some_and; my-llvm SAFETY-comment adjacency.src/abi/*.idr(nonexistent) → real Idris tree via ipkg build (per-file--checkis a known fake gate).Planned: src/{hir,mir,runtime}→ the shipped crates.Baselined (7 entries, expire 2026-10-27, tracked in #145): parser
self.expect()name-collision FP (157×), my-fmt infallible Write-to-String unwraps (26×), my-llvm internal-invariant unwraps (3×), my-mir/string.rs deliberate invariant expects, measure_depth example, modules.md illustrative user-project paths.Verified: ran the reusable's own
apply-baseline.shlocally against the post-fix finding set → 7 suppressed, 0 kept, exit 0.cargo test -p my-hir -p my-lintgreen.Hygiene (owner-approved):
.gitignoresecrets entries salvaged from the 07-26 sweep stash;mise.tomlboilerplate → pinned rust 1.97.0.🤖 Generated with Claude Code